package com.tsingteng.cosfun.ui.abnormal;


import android.content.Intent;
import android.view.View;
import android.widget.TextView;

import com.tsingteng.cosfun.R;
import com.tsingteng.cosfun.base.BasePresenterActivity;
import com.tsingteng.cosfun.common.Constant;
import com.tsingteng.cosfun.mvp.presenter.BasePresenter;
import com.tsingteng.cosfun.widget.TitleView;

import butterknife.BindView;

/**
 * 便当，视频不见了 界面
 * author  zht
 */
public class AbNormalActivity extends BasePresenterActivity implements TitleView.OnTitleClickListener{

    private String mNickName;
    private String messageType;
    @BindView(R.id.tv_ab_title_view)
    TitleView mTvAbTitleView;
    @BindView(R.id.message_tv)
    TextView mMessageTv;

    @Override
    protected void initData() {
        if ("PARAS".equals(messageType)){
            mTvAbTitleView.setTitle("");
            mTvAbTitleView.setIvLeft(R.drawable.back_big_icon);
            mTvAbTitleView.setOnTitleClickListener(this);
        }else if ("VIDEO".equals(messageType)){
            mMessageTv.setText(getResources().getString(R.string.message_video));
            mTvAbTitleView.setVisibility(View.GONE);
        }
    }

    @Override
    protected BasePresenter createPresenter() {
        return null;
    }


    @Override
    protected int getLayoutId() {
        return R.layout.activity_ab_normal;
    }

    @Override
    protected void getIntentData(Intent intent) {
       mNickName=intent.getStringExtra(Constant.ABNORMAL);
       messageType=intent.getStringExtra(Constant.MESSAGETYPE);
    }

    @Override
    public void onLeft() {
        this.finish();
    }

    @Override
    public void onRight() {

    }

    @Override
    public void onRight2() {

    }
}
